Skip to main content

Retrieve Test Provider Details

GET /api/v1/test-providers/{testProviderId}

Description

Retrieves detailed information about a specific test provider, including their name, description, and address. This endpoint is useful for obtaining comprehensive details about a provider, which can be essential for managing contracts, audits, or coordinating testing services.

Method: GET

URL Parameters:

  • testProviderId (required): The unique identifier of the test provider whose details are to be retrieved. This is a string that must be included in the URL path.

Example Request:

curl -G "http://[base_url]/api/v1/test-providers/{testProviderId}" \
-H "Authorization: Bearer [access_token]"

Responses:

  • 200 OK: Successfully retrieved detailed information about the test provider. The response includes comprehensive details such as the provider's name, description, and address.

Example Response:

{
"providerId": "123",
"name": "Quality Labs",
"description": "Provides comprehensive and accredited quality testing for agricultural products.",
"address": "123 Lab Street, Metro City"
}

Error Responses:

  • 400 Bad Request: Incorrect or incomplete path parameters.
  • 404 Not Found: No test provider found with the provided testProviderId.
  • 403 Forbidden: The user does not have permission to view the test provider details.

LANGUAGE

AUTHORIZATION

Bearer

CURL REQUEST


curl --request GET \ 
--url /api/v1/test-providers/{testProviderId} \
--header 'accept: application/json' \
--header 'content-type: application/json'

RESPONSE


Click Try It! to start a request and see the response here!